package com.jt.aop;

import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;

@Component
@Aspect
@Order(1)
public class SpringAOP2 {

    //环绕
    @Around("@annotation(com.jt.anno.Wbh)")
    public Object around(ProceedingJoinPoint joinPoint) throws Throwable {
        System.out.println("我是环绕通知B开始");
        Object result = joinPoint.proceed();
        System.out.println("我是环绕通知B结束");
        return result;
    }


}
